package com.panda.takeaway.entity.po;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.Date;

/**
 * @author John
 * @create 2021-08-06-10:52
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
@TableName("business")
public class Order extends BaseEntity{

    @TableId(value = "id",type = IdType.AUTO)
    private Long id;
    @TableField("user_id")
    private Long userId;
    @TableField("order_num")
    private String orderNum;
    @TableField("shop_id")
    private Long shopId;
    @TableField("address_id")
    private Long addressId;
    @TableField("note")
    private String note;
    @TableField("price")
    private Integer price;
    @TableField("batch_id")
    private Long batchId;
    @TableField("status")
    private byte status;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @TableField(value = "create_time",fill = FieldFill.INSERT)
    private Date createTime;

}
